import { Table, Button, Descriptions } from "antd";
import DarkCard from "../../../../../../common/DarkCard";
import { CloseOutlined } from "@ant-design/icons";
import biaoge from "../../../Zhpg/Yxfx/YxfxXq/biaoge";
export default function XqList(props) {
    const { xqList, cztxl, jzzyxl } = props;
    const data = JSON.parse(xqList?.xq)
    const btzd = biaoge();
    // console.log('xqListbtzd',btzd[`${xqList?.yhlx}`])
    console.log('data', data)
    return <>
        <DarkCard style={{
            position: 'absolute',
            right: '10px',
            width: '300px',
            top: '20px',
            bottom: '20px',
            pointerEvents: 'auto',
            borderRadius: 8,
        }} className="layout-v">
            <div style={{
                fontSize: 20,
                fontWeight: "bold",
                borderBottom: "1px solid #eee",
                paddingBottom: 12,
                marginBottom: 12
            }} className='layout-h center'>
                <div className='fill w0'>{xqList?.yhmc}</div>
                <div>
                    <Button size="small" icon={<CloseOutlined />} style={{
                        // color: "#fff"
                        background: "#00000000"
                    }} onClick={e => {
                        props.onClose?.()
                    }} />
                </div>
            </div>
            <Descriptions column={1} bordered size='large' className="fill h0" style={{
                overflow: 'auto'
            }}>
                {
                    Object.entries(data).map(([key, value]) => {
                        //console.log("key",key)

                        return (
                            <Descriptions.Item label={btzd[`${data?.Yhlx}`][key]}>{value}</Descriptions.Item>
                        )


                    })
                }
            </Descriptions>
        </DarkCard>

    </>
}